<template>
  <div>
      <el-descriptions title="基础数据" class="margin-top" :column="3" size="medium" border>
        <el-descriptions-item>
          <template slot="label">
            <i class="el-icon-user"></i>
            商品名称
          </template>
              {{ spu.SpuName }}
        </el-descriptions-item>
        <el-descriptions-item>
          <template slot="label">
            <i class="el-icon-mobile-phone"></i>
            价格
          </template>
          {{ spu.Price }}
        </el-descriptions-item>
        <el-descriptions-item>
          <template slot="label">
            <i class="el-icon-location-outline"></i>
            状态
          </template>
          {{ spu.Status == 1 ? "已上架" : "未上架" }}
        </el-descriptions-item>
        <el-descriptions-item>
          <template slot="label">
            <i class="el-icon-tickets"></i>
            商品说明
          </template>
          {{ spu.Caption }}
        </el-descriptions-item>
        <el-descriptions-item>
          <template slot="label">
            <i class="el-icon-office-building"></i>
            商品介绍
          </template>
          {{ spu.Introduction }}
        </el-descriptions-item>
      </el-descriptions>
  </div>
</template>

<script>
import SpuApi from "@/api/SpuApi";

export default {
  props: ["Id"],
  data() {
    return {
      spu: {},
    };
  },
  methods: {
  },
  created() {
    SpuApi.getById(this.Id).then((res) => {
      this.spu = res.data;
    });
  },
};
</script>

<style>
</style>